Release 10.1A: OpenEdge Development:
ADM Reference
callstringtt.p procedure
External procedure that allows a single RUN statement to invoke a call using a string that defines the parameters and pass up to 64 temp-tables. This procedure is useful for minimizing the number of request it takes to invoke a call on the AppServer.
All outputs and return values from the invoked procedure are available through the properties or parameters supplied as parameters.
Parameters:pcCallName INPUT CHARACTERName of an external or internal procedure or function to be invoked.
pcTargetObjec INPUT CHARACTERName of a manager procedure, the filename of a relatively or absolutely pathed procedure, or an integer value that evaluates to a procedure handle. If the value of this parameter is
""or?, by default, pcCallName contains the name of a procedure that is to be run nonpersistently.The parameter is optional. If nothing is specified, then
""or?is passed.pcTargetFlags INPUT CHARACTERThis parameter can contain modifiers that are used to invoke the persistent procedure. A modifier can be a valid combination of the following:
- P(ersistent) — Indicates that a new instance of the procedure should be instantiated persistently and left running.
- A(DM2) — Indicates that a new instance of an ADM2 procedure should be invoked persistently and the initializeObject internal procedure called to initialize it. The ADM2 procedure is left running after the call is complete.
- S(ingle) — Indicates that a new instance of the procedure should be instantiated if a running version is not found and left running.
- K(ill) — Indicates that if a procedure was instantiated during the call, it should be deleted before control is returned. The default is to apply the behavior of the S parameter. As a result, a persistent procedure is started if it is not found by walking the procedure stack and is left running after the call is complete.
You can specify any of the P, A, or S modifiers in combination with K to shut down the procedure. For example, PK instructs the caller to instantiate a new instance of the procedure persistently and delete it when it is complete.
The parameter is optional. If nothing is specified, then
""is passedpcCallParmString INPUT CHARACTERA string containing the parameters to pass to the procedure or function that is being invoked. The string is a comma-separated list of parameters. Each parameter is a string consisting of space-delimited values in the form
"mode data type parameter"where:
modeis one of INPUT, OUTPUT, INPUT-OUTPUT, or OUTPUT-APPEND.data typeis one of CHARACTER, DATE, LOGICAL, INTEGER, DECIMAL, RAW, HANDLE, TABLE-HANDLE, or ROWID.parameteris the name of either a property that was previously set using setPropertyList or setSessionParam, or a single quoted constant that does not contain spaces or commas. If a property is specified, the procedure attempts to evaluate the property value by calling getPropertyList. If no property is available, or Dynamics is not running, a call is made to getSessionParam for the property value. If neither call succeeds, the unknown value is passed.If the mode of the parameter is either OUTPUT or INPUT-OUTPUT, the property that is specified contains the output value of the call after the call is complete. If the
data typeis either HANDLE or TABLE-HANDLE, theparametercan also be an integer value between 1 and 32 that maps to one of the tables passed in with the call.The parameter is optional. If nothing is specified, then "" or
?is passed.pcHandlesToSkip INPUT CHARACTERBy default, the call wrapper does a DELETE OBJECT on tables that are listed in phCallTableHandle01 through 64 before returning. This avoids memory leaks caused by the duplication of temp-tables. In some cases, this behavior might be undesirable, such as when the table being returned is a dynamics temp-table that should be retained in the cache on the server.
To address this issues, this parameter allows a comma- separated list of numbers between 1 and 64 corresponding to the handles below. If a number is found in the list, the corresponding handle is not deleted in the procedure prior to control returning to the caller.
Note: Using an * in a CAN-DO list indicates that none of the handles should be deleted.The parameter is optional. If nothing is specified, then
""is passed.phCallTableHandle01 to phCallTableHandle64 INPUT-OUTPUT TABLE-HANDLEA table-handle that needs to be passed into the call.
The parameter is optional. If nothing is specified, then
Notes:?is passed.
- Once the procedure finishes executing, all temporary handles are deleted and the ttCall record no longer exists for the call. As a result, the Dynamic Call Wrapper has no information about this call so that there are no memory leaks created by calling
callstring.p.- The caller is responsible for cleaning up phCallParmTT and phCallParmTH and the phCallTempTable or phCallTableHandle objects.
- When execution passes to
callstringtt.p, the procedure creates an array of 64 handles and stores the values of the handles passed into the array so that temp-table copying is done only when required to invoke the call.- If the mode of the parameter is OUTPUT or INPUT-OUTPUT and a property that was set using setPropertyList is specified, the value of the property is set on the server side. It is not synchronized with the client unless the entire call is executed on the client side.
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |